﻿@namespace MudBlazor
@inherits MudComponentBase

<div @attributes="UserAttributes" class="mud-nav-group" disabled="@Disabled" style="@Style">
    <button @onclick="ExpandedToggle" tabindex="0" class="@Classname">
        @if (!String.IsNullOrEmpty(Icon))
        {
            <MudIcon Icon="@Icon" Color="@IconColor" Class="@IconClassname" />
        }
        <div Class="mud-nav-link-text">
            @Title
        </div>
        @if (!HideExpandIcon)
        {
            <MudIcon Icon="@ExpandIcon" class="@(Expanded? "mud-nav-link-expand-icon mud-transform" : "mud-nav-link-expand-icon")" />
        }
    </button>
    <MudCollapse Expanded="@Expanded" MaxHeight="@MaxHeight" Class="mud-navgroup-collapse">
        <MudNavMenu>
            @ChildContent
        </MudNavMenu>
    </MudCollapse>
</div>